home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 21 / AACD 21.iso / AACD / Utilities / Ghostscript / src / icstate.h < prev    next >
Encoding:
C/C++ Source or Header  |  2001-01-01  |  2.6 KB  |  72 lines

  1. /* Copyright (C) 1998, 2000 Aladdin Enterprises.  All rights reserved.
  2.   
  3.   This file is part of AFPL Ghostscript.
  4.   
  5.   AFPL Ghostscript is distributed with NO WARRANTY OF ANY KIND.  No author or
  6.   distributor accepts any responsibility for the consequences of using it, or
  7.   for whether it serves any particular purpose or works at all, unless he or
  8.   she says so in writing.  Refer to the Aladdin Free Public License (the
  9.   "License") for full details.
  10.   
  11.   Every copy of AFPL Ghostscript must include a copy of the License, normally
  12.   in a plain ASCII text file named PUBLIC.  The License grants you the right
  13.   to copy, modify and redistribute AFPL Ghostscript, but only under certain
  14.   conditions described in the License.  Among other things, the License
  15.   requires that the copyright notice and this notice be preserved on all
  16.   copies.
  17. */
  18.  
  19. /*$Id: icstate.h,v 1.4 2000/09/19 19:00:42 lpd Exp $ */
  20. /* Externally visible context state */
  21.  
  22. #ifndef icstate_INCLUDED
  23. #  define icstate_INCLUDED
  24.  
  25. #include "imemory.h"
  26. #include "iref.h"
  27. #include "idsdata.h"
  28. #include "iesdata.h"
  29. #include "iosdata.h"
  30.  
  31. /*
  32.  * Define the externally visible state of an interpreter context.
  33.  * If we aren't supporting Display PostScript features, there is only
  34.  * a single context.
  35.  */
  36. #ifndef gs_context_state_t_DEFINED
  37. #  define gs_context_state_t_DEFINED
  38. typedef struct gs_context_state_s gs_context_state_t;
  39. #endif
  40. struct gs_context_state_s {
  41.     gs_state *pgs;
  42.     gs_dual_memory_t memory;
  43.     int language_level;
  44.     ref array_packing;        /* t_boolean */
  45.     ref binary_object_format;    /* t_integer */
  46.     long rand_state;        /* (not in Red Book) */
  47.     long usertime_total;    /* total accumulated usertime, */
  48.                 /* not counting current time if running */
  49.     bool keep_usertime;        /* true if context ever executed usertime */
  50.     int in_superexec;        /* # of levels of superexec */
  51.     /* View clipping is handled in the graphics state. */
  52.     ref userparams;        /* t_dictionary */
  53.     int scanner_options;    /* derived from userparams */
  54.     ref stdio[3];        /* t_file */
  55.     /* Put the stacks at the end to minimize other offsets. */
  56.     dict_stack_t dict_stack;
  57.     exec_stack_t exec_stack;
  58.     op_stack_t op_stack;
  59. };
  60. extern const long rand_state_initial; /* in zmath.c */
  61.  
  62. /*
  63.  * We make st_context_state public because zcontext.c must subclass it.
  64.  */
  65. /*extern_st(st_context_state); *//* in icontext.h */
  66. #define public_st_context_state()    /* in icontext.c */\
  67.   gs_public_st_complex_only(st_context_state, gs_context_state_t,\
  68.     "gs_context_state_t", context_state_clear_marks,\
  69.     context_state_enum_ptrs, context_state_reloc_ptrs, 0)
  70.  
  71. #endif /* icstate_INCLUDED */
  72.